package com.shopx.task.job;

import com.shopx.cm.service.ICmMaterialService;
import com.shopx.cm.service.ICmSendService;
import com.shopx.task.AbstractQuatazJob;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * 材料跟单数据同步
 *
 * @author:lituo
 * @date:2023/3/15
 **/
@Slf4j
@Service
public class SyncMaterialSendJob extends AbstractQuatazJob {
  @Resource
  private ICmSendService cmSendService;

  @Override
  public void execute() {
    log.info("SyncMaterialSendJob.begin");
    try{
      cmSendService.syncErpData();
    }catch (Exception e){
      log.error("SyncMaterialSendJob.error",e);
    }
    log.info("SyncMaterialSendJob.end");
  }


}
